package com.dongdong.fallback;

import com.dongdong.api.SellerApi;
import com.dongdong.model.TbSeller;
import org.springframework.cloud.openfeign.FallbackFactory;

public class SellerFallBackFactory implements FallbackFactory<SellerApi> {


    @Override
    public SellerApi create(Throwable cause) {
        return new SellerApi() {
            @Override
            public TbSeller getSellerByName(String username) {
                return new TbSeller();
            }

            @Override
            public void addSeller(TbSeller seller) {

            }
        };
    }
}
